<?php
/* @var $this BranchesController */
/* @var $model Branches */
/* @var $form CActiveForm */
?>

<div class="form">

<?php $form=$this->beginWidget('CActiveForm', array(
	'id'=>'branches-form',
	'enableAjaxValidation'=>false,
)); ?>

	<p class="note">Fields with <span class="required">*</span> are required.</p>

	<?php echo $form->errorSummary($model); ?>

	<div class="row">
		<?php echo $form->labelEx($model,'branches_id'); ?>
		<?php echo $form->textField($model,'branches_id'); ?>
		<?php echo $form->error($model,'branches_id'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'branch_name'); ?>
		<?php echo $form->textField($model,'branch_name',array('size'=>45,'maxlength'=>45)); ?>
		<?php echo $form->error($model,'branch_name'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'branch_address'); ?>
		<?php echo $form->textField($model,'branch_address',array('size'=>45,'maxlength'=>45)); ?>
		<?php echo $form->error($model,'branch_address'); ?>
	</div>

	
<div>
<?php echo $form->labelEx($model,'employee_id'); ?>
<?php echo $form->dropDownList($model, 'employee_id', CHtml::listData(
Employee::model()->findAll(), 'id', 'employee_id','employee_name'),
array('prompt' => 'Select a Employee')
); ?>
<?php echo $form->error($model,'employee_id'); ?>
</div>
	<div class="row buttons">
		<?php echo CHtml::submitButton($model->isNewRecord ? 'Create' : 'Save'); ?>
	</div>

<?php $this->endWidget(); ?>

</div><!-- form -->